package net.fenghaitao.annotation;

import net.fenghaitao.handler.CareatedByValidator;

import javax.validation.Constraint;
import javax.validation.Payload;
import java.lang.annotation.*;

@Constraint(validatedBy = CareatedByValidator.class)
@Documented
@Target({ElementType.METHOD, ElementType.FIELD,
        ElementType.ANNOTATION_TYPE, ElementType.CONSTRUCTOR,
        ElementType.PARAMETER, ElementType.TYPE_USE})
@Retention(RetentionPolicy.RUNTIME)
public @interface ValidatorCareatedBy {

    String message() default "创建人不合法！！";

    Class<?>[] groups() default {};

    Class<? extends Payload>[] payload() default {};
}
